'use strict';

/**
 * @ngdoc function
 * @name jgappApp.controller:AddressbookIndexCtrl
 * @description
 * # AddressbookIndexCtrl
 * Controller of the jgappApp
 */
angular.module('jgappApp')
    .controller('AddressbookIndexCtrl', function (ContactInfo , $location) {
        var vm = this;
        this.initData = function () {
            ContactInfo.getData().then(function (data) {
                vm.contactInfo = data;
            })
        }
        this.initData();
        this.gochoosepeople = function (item) {
            $location.path("addressbook/userdetail/" + item.id)
        };
    });
